/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */

package ModeloDatos;

import java.io.Serializable;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.NamedQueries;
import javax.persistence.NamedQuery;
import javax.persistence.Table;
import javax.xml.bind.annotation.XmlRootElement;

/**
 *
 * @author fernando.parodi
 */
@Entity
@Table(name = "tbl_cliente")
@XmlRootElement
@NamedQueries({
    @NamedQuery(name = "TblCliente.findAll", query = "SELECT t FROM TblCliente t"),
    @NamedQuery(name = "TblCliente.findByCodCliente", query = "SELECT t FROM TblCliente t WHERE t.codCliente = :codCliente"),
    @NamedQuery(name = "TblCliente.findByNombre", query = "SELECT t FROM TblCliente t WHERE t.nombre = :nombre"),
    @NamedQuery(name = "TblCliente.findByApellidoPaterno", query = "SELECT t FROM TblCliente t WHERE t.apellidoPaterno = :apellidoPaterno"),
    @NamedQuery(name = "TblCliente.findByApellidoMaterno", query = "SELECT t FROM TblCliente t WHERE t.apellidoMaterno = :apellidoMaterno"),
    @NamedQuery(name = "TblCliente.findByDni", query = "SELECT t FROM TblCliente t WHERE t.dni = :dni"),
    @NamedQuery(name = "TblCliente.findByDireccion", query = "SELECT t FROM TblCliente t WHERE t.direccion = :direccion"),
    @NamedQuery(name = "TblCliente.findByDistrito", query = "SELECT t FROM TblCliente t WHERE t.distrito = :distrito"),
    @NamedQuery(name = "TblCliente.findByTelefono", query = "SELECT t FROM TblCliente t WHERE t.telefono = :telefono"),
    @NamedQuery(name = "TblCliente.findByCelular", query = "SELECT t FROM TblCliente t WHERE t.celular = :celular")})
public class TblCliente implements Serializable {
    private static final long serialVersionUID = 1L;
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Basic(optional = false)
    @Column(name = "CodCliente")
    private Integer codCliente;
    @Column(name = "Nombre")
    private String nombre;
    @Column(name = "Apellido_Paterno")
    private String apellidoPaterno;
    @Column(name = "Apellido_Materno")
    private String apellidoMaterno;
    @Column(name = "DNI")
    private String dni;
    @Column(name = "Direccion")
    private String direccion;
    @Column(name = "Distrito")
    private String distrito;
    @Column(name = "Telefono")
    private String telefono;
    @Column(name = "Celular")
    private String celular;

    public TblCliente() {
    }

    public TblCliente(Integer codCliente) {
        this.codCliente = codCliente;
    }

    public Integer getCodCliente() {
        return codCliente;
    }

    public void setCodCliente(Integer codCliente) {
        this.codCliente = codCliente;
    }

    public String getNombre() {
        return nombre;
    }

    public void setNombre(String nombre) {
        this.nombre = nombre;
    }

    public String getApellidoPaterno() {
        return apellidoPaterno;
    }

    public void setApellidoPaterno(String apellidoPaterno) {
        this.apellidoPaterno = apellidoPaterno;
    }

    public String getApellidoMaterno() {
        return apellidoMaterno;
    }

    public void setApellidoMaterno(String apellidoMaterno) {
        this.apellidoMaterno = apellidoMaterno;
    }

    public String getDni() {
        return dni;
    }

    public void setDni(String dni) {
        this.dni = dni;
    }

    public String getDireccion() {
        return direccion;
    }

    public void setDireccion(String direccion) {
        this.direccion = direccion;
    }

    public String getDistrito() {
        return distrito;
    }

    public void setDistrito(String distrito) {
        this.distrito = distrito;
    }

    public String getTelefono() {
        return telefono;
    }

    public void setTelefono(String telefono) {
        this.telefono = telefono;
    }

    public String getCelular() {
        return celular;
    }

    public void setCelular(String celular) {
        this.celular = celular;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (codCliente != null ? codCliente.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof TblCliente)) {
            return false;
        }
        TblCliente other = (TblCliente) object;
        if ((this.codCliente == null && other.codCliente != null) || (this.codCliente != null && !this.codCliente.equals(other.codCliente))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return "ModeloDatos.TblCliente[ codCliente=" + codCliente + " ]";
    }
    
}
